home *** CD-ROM | disk | FTP | other *** search
/ Aminet 30 / Aminet 30 (1999)(Schatztruhe)[!][Apr 1999].iso / Aminet / comm / mail / liststats.lha / ListStats / Arexx / ListStats_Quit.rexx next >
OS/2 REXX Batch file  |  1998-08-17  |  2KB  |  39 lines

  1. /* Instruct ListStats to quit and save all mailing lists                    */
  2. /* -=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-                    */
  3. /* This file contains the script to signal ListStats to save all it's list  */
  4. /* data and quit. For correct operation it should be executed by your mail  */
  5. /* browser just before it exits. In YAM2 you can do this by opening the     */
  6. /* Config window and selecting "Arexx" from the settings list. Then you     */
  7. /* select "Program Termination" from the scripts listview and enter the     */
  8. /* FULL path of this script in the Script string box. eg:                   */
  9. /*                                                                          */
  10. /*     CODE:ListStats/Arexx/ListStats_Quit.rexx                             */
  11. /*                                                                          */
  12. /* is the path on my system.                                                */
  13. /*                                                                          */
  14. /* ListStats and all it's associated documentation and scripts are Copyright*/
  15. /* ©1998 Chris Page, The World Foundry. All rights reserved.                */
  16.  
  17. options results
  18. ADDRESS COMMAND
  19.  
  20. /* Setup STDERR */
  21. DO_STDERR = 0;
  22. IF OPEN(STDERR, "CON:////ListStats_Scan.rexx -- Error messages window/WAIT/AUTO", "w") then DO_STDERR = 1
  23.  
  24. /* Check ListStats is running...  */
  25. if ~show('p', 'LISTSTATS') then do
  26.     call writeln(STDERR, "ListStats not found!")
  27.     call quit
  28. end
  29.  
  30. address LISTSTATS exit
  31.  
  32. error:
  33. syntax:
  34. quit:
  35.  
  36. if DO_STDERR then call close(STDERR);
  37.  
  38. exit 0
  39.